package com.hyz.user.feign;

import com.hyz.common.pojo.Order;
import com.hyz.common.response.Result;
import com.hyz.user.feign.fallback.OrderFeignFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

@FeignClient(value="order-service",fallback= OrderFeignFallback.class)
public interface OrderApi {

    @GetMapping("order/findOrderByUserId/{username}")
    public List<Order> findOrderByUserId(@PathVariable("username") String username);
}
